package com.hns.frame.security;

import java.io.IOException;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.security.access.AccessDeniedException;
import org.springframework.security.web.access.AccessDeniedHandlerImpl;

import com.hns.frame.util.ResponseUtil;


/**
 * 无权限操作
 * @author:Fisher
 * @email:zhuangcaijin@126.com
 * @version Revision 2.0.0
 */
public class AppAccessDeniedHandler extends AccessDeniedHandlerImpl {
    public void handle(HttpServletRequest request, HttpServletResponse response, AccessDeniedException accessDeniedException)
        throws IOException, ServletException {
            ResponseUtil.error("对不起，您没有权限使用该功能!", "", request, response);
        }
}
